package main

import (
	"encoding/json"
	"fmt"
)


func main(){
	var slice []map[string]interface{}
	var map1 map[string]interface{}
	map1 = make(map[string]interface{})
	map1["name"] = "jack"
	map1["age"] = "7"
	map1["address"] = "北京"
	slice = append(slice,map1)
	map2 := make(map[string]interface{})
	map2["name"] = "Allen"
	map2["age"] = "12"
	map2["address"] = "上海"
	slice = append(slice,map2)
	data,err := json.Marshal(slice)
	if err != nil {
		fmt.Println(err)
	}
	fmt.Println(string(data))
}